<table width="98%" border="0" align="center" cellpadding="0" cellspacing="0">
    <tbody>
        <tr>
            <td class="bgtitle">
                <table border="0" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF">
                    <tbody>
                        <tr>
                            <td width="20">
                                <img src="/templates/images/mui_ten.gif">
                            </td>
                            <td valign="bottom" class="title">Sản phẩm mới</td>
                            <td width="10" valign="bottom">&nbsp;</td>
                        </tr>
                    </tbody>
                </table>
            </td>
        </tr>
        <tr>
            <td valign="top">
                <img src="/templates/images/space.gif" width="1" height="10">
            </td>
        </tr>
    </tbody>
</table>
<table border="0" cellpadding="0" cellspacing="0" align="center">
    <tbody>
        <!-- 4 cái tr -->
        {foreach from=$product_hot item=product_hot_item}
			{if $product_hot_item@index % 3== 0}
				<tr>
				{/if}
				<td valign="top">
					<input name="idprocheck[]" type="hidden" value="259">
					<table width="260" border="0" align="center" cellpadding="0" cellspacing="0">
						<tbody>
							<tr>
								<td> 
									<table width="100%" border="0" cellspacing="0" cellpadding="0">
										<tbody>
											<tr>
												<td width="11">
													<img src="/templates/images/tbl_pro1.jpg" width="11" height="11">
												</td>
												<td background="/templates/images/tbl_pro2.jpg">
													<img src="/templates/images/tbl_pro2.jpg" width="1" height="11">
												</td>
												<td width="11">
													<img src="/templates/images/tbl_pro3.jpg" width="11" height="11">
												</td>
											</tr>
										</tbody>
									</table>
								</td>
							</tr>
							<tr>
								<td>
									<table width="100%" border="0" cellspacing="0" cellpadding="0">
										<tbody>
											<tr>
												<td width="11" style="background-image:url('/templates/images/tbl_pro4.jpg'); background-repeat:repeat-y; background-position:left top">&nbsp;</td>
												<td>
													<img src="/templates/images/posts.gif">&nbsp;
													<!-- Sửa -->
													<a href="/product/camera" class="linktitlebox">Máy ảnh</a> | 
													<a href="/{$product_hot_item.link}" class="linktitlebox">{$product_hot_item.categoryname}</a>
													{if $promotion_start == 1}
														<span style="float: right; font-weight: bold; margin-top: 2px; color:red">{$promotionbytime.percentdiscount}%</span>
														<img src="/templates/images/sale.png" style="float: right;">
													{/if}
												</td>
												<td width="11" style="background-image:url('/templates/images/tbl_pro5.jpg'); background-repeat:repeat-y; background-position:right top">&nbsp;</td>
											</tr>
											<tr>
												<td width="11" style="background-image:url('/templates/images/tbl_pro4.jpg'); background-repeat:repeat-y; background-position:left top">&nbsp;</td>
												<td height="270">
													<div align="center">
														<table width="100" border="0" cellpadding="0" cellspacing="0" align="center">
															<tbody>
																<tr>
																	<td align="left">
																		<!-- Sửa -->
																		<a style="cursor:hand" href="/productdetail/{$product_hot_item.idproduct}"> 
																			<img src="/templates/images/product/{$product_hot_item.image}" alt="{$product_hot_item.productname}" width="180" height="260" border="0"> 
																		</a>
																	</td>
																</tr>
															</tbody>
														</table>
													</div>
												</td>
												<td width="11" style="background-image:url('/templates/images/tbl_pro5.jpg'); background-repeat:repeat-y; background-position:right top">&nbsp;</td>
											</tr>
											<tr>
												<td width="11" style="background-image:url('/templates/images/tbl_pro4.jpg'); background-repeat:repeat-y; background-position:left top">&nbsp;</td>
												<td height="50" valign="top">
													<div align="center">
														<h3 style="margin:0px;">
															<!-- Sửa -->
															<a style="cursor:hand" href="/productdetail/{$product_hot_item.idproduct}" class="linkblack">{$product_hot_item.productname}</a>
														</h3>
														<span class="{if $promotion_start == 1}fontgrayprice{else}fontred{/if}">{$product_hot_item.price|number_format} VNĐ</span>
														<br>
														{if $promotion_start == 1}
															<img src="/templates/images/sale_arrow.png" style="position: absolute; margin-top: -11px; margin-left: -60px;">
															<span class="fontred">{($product_hot_item.price*(100-$promotionbytime.percentdiscount)/100)|number_format} VNĐ</span>
															<br>
														{/if}
														<span class="fontgreen">{$product_hot_item.promotion}</span>
													</div>
												</td>
												<td width="11" style="background-image:url('/templates/images/tbl_pro5.jpg'); background-repeat:repeat-y; background-position:right top">&nbsp;</td>
											</tr>
										</tbody>
									</table>
								</td>
							</tr>
							<tr>
								<td>
									<table width="100%" border="0" cellspacing="0" cellpadding="0">
										<tbody>
											<tr>
												<td width="11">
													<img src="/templates/images/tbl_pro6.jpg" width="11" height="44"></td>
												<td background="/templates/images/tbl_pro7.jpg" style="padding-bottom:3px">
													<form action="/cart/add/{$product_hot_item.idproduct}" method="post" style="margin:0">
														<table border="0" align="center" cellpadding="2" cellspacing="0">
															<!-- Sửa -->
															<input type="hidden" name="idcth" value="{$product_hot_item.productid}">
															<input type="hidden" name="proname" value="{$product_hot_item.productname}">
															<input type="hidden" name="price" value="{$product_hot_item.price}">
															<input type="hidden" name="poids" value="">
															<input type="hidden" name="img" value="{$product_hot_item.image}">
															<tbody>
																<tr>
																	<!-- Nút chi tiết  -->
																	<td>
																		<a style="cursor:hand" href="/productdetail/{$product_hot_item.idproduct}">
																			<img src="/templates/images/but-detail.jpg" border="0"></a>
																	</td>
																	<td width="2">
																		<img src="/templates/images/space.gif" width="2">
																	</td>
																	<!--nut mua-->
																	<td>
																		{if ($product_hot_item.inventory - $product_hot_item.quantity_buying) > 0}
																			<input type="image" src="/templates/images/but-book.jpg"></a>
																		{else}
																			<span class="fontred">Hết hàng</span>
																		{/if}
																	</td>
																</tr>
															</tbody>
														</table>
													</form>
												</td>
												<td width="11">
													<img src="/templates/images/tbl_pro8.jpg" width="11" height="44">
												</td>
											</tr>
										</tbody>
									</table>
								</td>
							</tr>
						</tbody>
					</table>
				</td>
				{if $product_hot_item@index %3 == 2}
				</tr>
			{/if}
		{/foreach}
    </tbody>
</table>
<br>